package com.lrkj.notice.domain;

import java.util.Date;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.lrkj.common.annotation.Excel;
import com.lrkj.common.core.domain.BaseEntity;
import lombok.Data;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;

/**
 * 站内消息对象 notice_site_message
 *
 * @author yajun_ren
 * @date 2022-09-07
 */
@Data
public class NoticeSiteMessage extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /** 主键 */
    private String id;

    /** 消息标题 */
    @Excel(name = "消息标题")
    private String title;

    /** 消息内容 */
    @Excel(name = "消息内容")
    private String content;

    /** 发送者ID */
    private String senderId;

    /** 发送者姓名 */
    @Excel(name = "发送者姓名")
    private String senderName;

    /** 发送时间 */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date senderTime;

    /** 消息类型 */
    @Excel(name = "消息类型")
    private String messageType;

    /** 接收类型 */
    @Excel(name = "接收类型")
    private String receiveType;

    /** 发布状态 */
    @Excel(name = "发布状态")
    private String sendState;

    /** 截止有效期 */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date efficientTime;

    /** 撤回时间 */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date cancelTime;

    //指定用户IDS
    private String userIds;


    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
            .append("id", getId())
            .append("title", getTitle())
            .append("content", getContent())
            .append("senderId", getSenderId())
            .append("senderName", getSenderName())
            .append("senderTime", getSenderTime())
            .append("messageType", getMessageType())
            .append("receiveType", getReceiveType())
            .append("sendState", getSendState())
            .append("efficientTime", getEfficientTime())
            .append("cancelTime", getCancelTime())
            .append("createBy", getCreateBy())
            .append("createTime", getCreateTime())
            .append("updateBy", getUpdateBy())
            .append("updateTime", getUpdateTime())
            .toString();
    }
}
